﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace KnBinarySerializer.Tests.Ent
{
    internal class ParmTable
    {
        public string TableName { get; set; }
        public ParmColumnCollection Columns { get; private set; }
        public List<ParmRow> Rows { get; private set; }

        public ParmTable()
        {
            Rows = new List<ParmRow>();
            Columns = new ParmColumnCollection();
        }
        public void ImportRow(ParmRow row)
        {
            Rows.Add(row);
        }
    }

    public class ParmColumnCollection : List<ParmColumn>
    {
        public void Add(string columnName, Type dataType)
        {
            ParmColumn col = new ParmColumn();
            col.Name = columnName;
            col.DbType = dataType;
            Add(col);
        }
    }
}
